import React from 'react';
import { Provider } from 'react-redux';
import { GlobalStyle } from './style';
import { IconStyle } from './assets/iconfont/iconfont';
import { renderRoutes } from 'react-router-config';
import store from './store/index';
import routes from './routes/index';
import { BrowserRouter } from 'react-router-dom';

export default function App () {
  return (
    <Provider store={store}>
        <BrowserRouter>
        <GlobalStyle></GlobalStyle>
        <IconStyle></IconStyle>
        { renderRoutes (routes) }
      </BrowserRouter>
    </Provider>
  )
};
